<?php
class Zendvn_Cache_File extends Zend_Cache {
	
	public function __construct($frontend,$prefix,$lifetime,$dir){
		$backend = 'File';
		$frontendOptions = array('cache_id_prefix' => $prefix,
								 'automatic_serialization' => true,		
								 'lifetime' => $lifetime );
		$backendOptions = array('cache_dir' => $dir);
		$caching  = Zend_Cache::factory($frontend, $backend, $frontendOptions, $backendOptions);
		return $caching;
		//chu y ham save("index content 1" ,"data_1",array("indexcontent1"))
		//tạo 1 file cache có giá trị "index content 1" có Tag là "data_1" ,
		// trong cache có ID là "indexcontent1"		
	}
		
}